/* ====================================================================
 * (#)Header: RuleServiceImpl.java
 * (#)Revision: 
 * (#)Date Created: Sep 30, 2011 12:47:15 AM
 * (#)Created By: Karol Wozniak
 * ====================================================================
 * 
 *
 * Copyright (c) 2007 karolak .  All rights reserved.
 *
 * ====================================================================
 * 
 * The software application represented here is the sole property of 
 * karolak. Its unauthorized utilization is expressly prohibited.
 * 
 * ====================================================================
 */
package com.karolak.service.rules;

import java.util.List;

import com.karolak.rules.RuleEngine;
import com.karolak.rules.RuleFileType;

/**
 * <code>RuleServiceImpl</code> is used to ....
 * 
 * @author <a href="mailto:kwozniak@hotmail.com">Karol Wozniak</a>
 */
public class RuleServiceImpl implements RuleService {

	private RuleEngine ruleEngine;

	public String loadRuleSet(StringBuilder ruleString, RuleFileType fileType) {
		return getRuleEngine().loadRuleSet(ruleString, fileType);
	}

	public String loadRuleSet(String fileName, RuleFileType fileType) {
		return getRuleEngine().loadRuleSet(fileName, fileType);
	}

	public List<?> execute(String ruleExecutionSetUri, Object... args) {
		return getRuleEngine().execute(ruleExecutionSetUri, args);
	}

	public List<?> execute(String ruleExecutionSetUri, List<?> data) {
		return getRuleEngine().execute(ruleExecutionSetUri, data);
	}

	public RuleEngine getRuleEngine() {
		return ruleEngine;
	}

	public void setRuleEngine(RuleEngine ruleEngine) {
		this.ruleEngine = ruleEngine;
	}
}
